//
//  CommentsModel.m
//  ZITHER
//
//  Created by imac on 2018/6/11.
//  Copyright © 2018年 MinesTime. All rights reserved.
//

#import "CommentsModel.h"

@implementation CommentsModel
- (NSString *)avatar {
    return kIMAGE_URL(_avatar);
}

- (NSArray<NSString *> *)imgs {
    if (self.img && ![self.img isEqualToString:@""]) {
        NSMutableArray<NSString *> *tempArrM = @[].mutableCopy;
        for (NSString *imgStr in [self.img componentsSeparatedByString:@","]) {
//            if (![tempArrM containsObject:kIMAGE_URL(imgStr)]) {
                [tempArrM addObject:kIMAGE_URL(imgStr)];
//            }
        }
        return tempArrM.copy;
    }
    return nil;
}
@end
